package com.ternnetwork.batch.model.demo;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.TableGenerator;

import org.codehaus.jackson.annotate.JsonAutoDetect;

import com.thoughtworks.xstream.annotations.XStreamAlias;
import com.thoughtworks.xstream.annotations.XStreamOmitField;

@Entity
@Table(name="VS_CREDIT_BILL")
@JsonAutoDetect
@XStreamAlias("credit")
public class CreditBill {
	 
	@XStreamOmitField
	@Id@Column(name="ID",nullable=false)
	@GeneratedValue(strategy = GenerationType.TABLE,generator="id_gen")
    @TableGenerator(name = "id_gen",pkColumnValue="VS_CREDIT_BILL_ID",table="VS_ID_GENERATOR", pkColumnName="GEN_NAME",valueColumnName="GEN_VALUE",allocationSize=1)
	private Long id;
	
	    @XStreamAlias("accountID")
	    @Column(name="ACCOUNT_ID")
	    private String accountId;

	    @XStreamAlias("name")
	    @Column(name="NAME")
	    private String name;

	    @XStreamAlias("amount")
	    @Column(name="AMOUNT")
	    private Double  amount;

	    @XStreamAlias("date")
	    @Column(name="CREDIT_DATE")
	    private String date;

	    @XStreamAlias("address")
	    @Column(name="ADDRESS")
	    private String address;

	    @XStreamOmitField
	    @Column(name="BATCH_NO")
	    private String batchNo;
	    
	    @XStreamOmitField
	    @Column(name="MOBILE_PHONE_NO")
	    private String mobilePhoneNo;
	    
	    @XStreamOmitField
	    @Column(name="STATUS")
	    private Integer status;

	    public CreditBill() {
	        super();
	    }

	    public String getAccountId() {
	        return accountId;
	    }

	    public void setAccountId(String accountId) {
	        this.accountId = accountId;
	    }

	    public String getAddress() {
	        return address;
	    }

	    public void setAddress(String address) {
	        this.address = address;
	    }

	    public Double getAmount() {
	        return amount;
	    }

	    public void setAmount(Double amount) {
	        this.amount = amount;
	    }

	    public String getDate() {
	        return date;
	    }

	    public void setDate(String date) {
	        this.date = date;
	    }

	    public String getName() {
	        return name;
	    }

	    public void setName(String name) {
	        this.name = name;
	    }


	    public Long getId() {
			return id;
		}

		public void setId(Long id) {
			this.id = id;
		}

		public String getBatchNo() {
			return batchNo;
		}

		public void setBatchNo(String batchNo) {
			this.batchNo = batchNo;
		}

		public String getMobilePhoneNo() {
			return mobilePhoneNo;
		}

		public void setMobilePhoneNo(String mobilePhoneNo) {
			this.mobilePhoneNo = mobilePhoneNo;
		}

		public Integer getStatus() {
			return status;
		}

		public void setStatus(Integer status) {
			this.status = status;
		}

		
		public String toString() {
			return "CreditBill [id=" + id + ", accountId=" + accountId + ", name=" + name + ", amount=" + amount
					+ ", date=" + date + ", address=" + address + ", batchNo=" + batchNo + ", mobilePhoneNo="
					+ mobilePhoneNo + "]";
		}

		
}
